<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="_Default" MasterPageFile="~/MasterPageExpandable.master" Title="Home Page" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>

<%@ Register Src="~/DashboardControls/DashboardPlaceHolder.ascx" TagName="DashboardPlaceHolder"
    TagPrefix="uc1" %>

    
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">




        <script type="text/javascript" language="javascript">

    function setScroll(newPosition)
    {
       document.getElementById("HiddenScrollPositionValue").value=newPosition;
    }
    
       function getScroll(dashDiv, newPosition)
    {
       for (i=0;i<30;i++)
          {
          if (newPosition-getScrollTop(dashDiv)>300)
                   setScrollTop(dashDiv,getScrollTop(dashDiv)+300);
          
           if (newPosition-getScrollTop(dashDiv)<-300)
                   setScrollTop(dashDiv,getScrollTop(dashDiv)-300);
          }
         
         setScrollTop(dashDiv,newPosition);
        document.getElementById("HiddenScrollPositionValue").value=newPosition;
        
    }
    
    function getScrollTop(dashDiv)
    {
       try
       {
          return document.getElementById(dashDiv).scrollTop;
       }
       catch(e)
       {
          return document.getElementById(dashDiv).pageYOffset;
       }
    }
    
    function setScrollTop(dashDiv,newPosition)
    {
       try
       {
          document.getElementById(dashDiv).scrollTop=newPosition;
       }
       catch(e)
       {
          document.getElementById(dashDiv).pageYOffset=newPosition;
       }
    }
    
    function setScrollById(dashDiv)
    {
    var newposition=0;
    try
         {
          newposition=document.getElementById(dashDiv).scrollTop;
         }
     catch(e)
         {
          newposition=document.getElementById(dashDiv).pageYOffset; 
         }
         
       document.getElementById("HiddenScrollPositionValue").value=newposition;
    }
    
    
    </script>

    <table width="965px" border="0">
    <tr><td style="width:965px;height:0px; visibility:collapse;" colspan="2" align="left" valign="bottom">
          <asp:Literal ID="WelcomeLiteral" runat="server"></asp:Literal>
    </td></tr>
    <tr><td style="width:965px;height:10px;" colspan="2" align="left" valign="middle">
        
    </td></tr>
    <tr><td width="289px" valign="top" align="center">
    <div id="QuickLinksDiv" runat="server" style="height:400px; overflow:auto;">  
    <table border="0" cellpadding="0" cellspacing="0" bgcolor="#949FB1" style="width:240px;">
    <tr><td valign="top" align="left" style="height:9px;"><img id="LeftCornerImage" runat="server" src="images/cornerLeft.gif" alt=""   /></td>
    <td style="border-top:1px solid; border-color:#21334B;width:222px; height:9px;"><img id="Img1" runat="server" src="images/1x1.gif" alt=""  /></td>
    <td valign="top" align="right"> <img id="RightCornerImage" runat="server" src="images/cornerRight.gif" alt="" /></td>
    </tr><tr>
    <td style="border-left:1px solid; border-color:#21334B;width:9px;height:9px;">&nbsp;</td>
    <td align="left" valign="top" style="border-color:#21334B;width:222px;"><h2><span id="QuickLinksSpan" runat="server">Quick Links</span></h2></td>
    <td style="border-right:1px solid; border-color:#21334B;width:9px;">&nbsp;</td>
    </tr><tr style="height:90%">
    <td align="left" colspan="3" valign="top" style="background: url('images/gradient3.jpg') repeat-x 0% 0%; border:1px solid; border-color:#21334B; background-color:White; "  >
           <asp:Repeater ID="QuickLinksRepeater" runat="server">
           <HeaderTemplate><table border="0" cellpadding="0" cellspacing="0"><tr style="height:10px;"><td></td></tr></HeaderTemplate>
           <ItemTemplate> 
               <tr><td style="width:20px;"></td><td align="left"><asp:HyperLink runat="server" CssClass="homeQuickLinksSmall" ID="QuickLinksSmallHyperLink" NavigateUrl='<%# Eval("NavigateURL") %>'><%# GetDisplayName(Eval("Title")) %></asp:HyperLink></td></tr>
           </ItemTemplate>
           <FooterTemplate><tr style="height:10px;"><td></td></tr></table></FooterTemplate>
        </asp:Repeater>
       </td>
       </tr></table>
        <cc1:AutoCompleteExtender ID="AutoCompleteExtender1" runat="server"
                TargetControlID="QuickSearchTextBox"
                ServicePath="~/AJAX/AutoComplete.asmx" 
                BehaviorId="QuickSearchEx"
                ServiceMethod="GetParticipants"
                MinimumPrefixLength="1" 
                CompletionInterval="200"
                EnableCaching="true"
                CompletionSetCount="10"
                CompletionListCssClass="autocomplete_completionListElement" 
                CompletionListItemCssClass="autocomplete_listItem" 
                CompletionListHighlightedItemCssClass="autocomplete_highlightedListItem"
                DelimiterCharacters=";, :">
                <Animations>
                    <OnShow>
                        <Sequence>
                            <%-- Make the completion list transparent and then show it --%>
                            <OpacityAction Opacity="0" />
                            <HideAction Visible="true" />
                            
                            <%--Cache the original size of the completion list the first time
                                the animation is played and then set it to zero --%>
                            <ScriptAction Script="
                                // Cache the size and setup the initial size
                                var behavior = $find('QuickSearchEx');
                                if (!behavior._height) {
                                    var target = behavior.get_completionList();
                                    behavior._height = target.offsetHeight - 2;
                                    target.style.height = '0px';
                                }" />
                            
                            <%-- Expand from 0px to the appropriate size while fading in --%>
                            <Parallel Duration=".4">
                                <FadeIn />
                                <Length PropertyKey="height" StartValue="0" EndValueScript="$find('QuickSearchEx')._height" />
                            </Parallel>
                        </Sequence>
                    </OnShow>
                    <OnHide>
                        <%-- Collapse down to 0px and fade out --%>
                        <Parallel Duration=".4">
                            <FadeOut />
                            <Length PropertyKey="height" StartValueScript="$find('QuickSearchEx')._height" EndValue="0" />
                        </Parallel>
                    </OnHide>
                </Animations>
        </cc1:AutoCompleteExtender>
       <br />
       <table border="0" cellpadding="0" cellspacing="0" bgcolor="#949FB1" style="width:240px;">
    <tr id="trQuickSearchTop" runat="server"><td valign="top" align="left" style="height:9px;"><img id="Img2" runat="server" src="images/cornerLeft.gif" alt=""  /></td>
    <td style="border-top:1px solid; border-color:#21334B;width:222px; height:9px;"><img id="Img3" runat="server" src="images/1x1.gif" alt=""  /></td>
    <td valign="top" align="right"> <img id="Img4" runat="server" src="images/cornerRight.gif" alt="" /></td>
    </tr><tr runat="server" id="trQuickSearch1">
    <td style="border-left:1px solid; border-color:#21334B;width:9px;height:9px;">&nbsp;</td>
    <td align="left" valign="top" style="border-color:#21334B;width:222px;">
    
    <h2><span id="Span1" runat="server" >Participant Search</span></h2></td>
    <td style="border-right:1px solid; border-color:#21334B;width:9px;">&nbsp;</td>
    </tr><tr runat="server" id="trQuickSearch2" height='90%' style="background-color:White; ">
    <td align="left" colspan="3" valign="top" style="border-left:1px solid; border-right:1px solid; border-color:#21334B; background-color:White; "  >
         &nbsp; <asp:TextBox ID="QuickSearchTextBox" runat="server" AutoPostBack="true" ReadOnly="false" Columns="30" ToolTip="Quick File Search: start entering last name of participant."></asp:TextBox>
       </td>
       </tr>
       <tr runat="server" id="trQuickSearch3" style="background-color:White; ">
       <td colspan="3" style="border-left:1px solid; border-right:1px solid; border-bottom: 1px solid; border-color:#21334B; background-color:White;"><asp:Button ID="QuickSearchButton" runat="server" Text="View File" /></td></tr></table>
       </div>
   </td><td width="676px" style="border-color:#21334B; background-color:White;"  >
    <div  id="DashboardDiv" runat="server"  style="width:676px; height:400px; overflow:auto;">    
    <cc1:Accordion ID="DashBoardAccordion" runat="server" SelectedIndex="-1"
            HeaderCssClass="accordionHeader" HeaderSelectedCssClass="accordionHeaderSelected"
            ContentCssClass="accordionContent" FadeTransitions="false" FramesPerSecond="40" 
            TransitionDuration="250" AutoSize="None" RequireOpenedPane="false" SuppressHeaderPostbacks="true">
       <HeaderTemplate><a href=""><%#GetDisplayName(Eval("Title"))%></a></HeaderTemplate>
       <ContentTemplate> <asp:Panel runat="server" ID="DashboardItemPanel"></asp:Panel></ContentTemplate>
    </cc1:Accordion>
         </div>
    </td></tr></table>
   
     
    <input type="hidden" id="HiddenScrollPositionValue" name="HiddenScrollPositionValue" value="0" />
     

</asp:Content>

<asp:Content ID="ContentFixed" runat="server" ContentPlaceHolderID="ContentPlaceHolder2">
</asp:Content>
